/*
 * @Author: guandeshen 295570679@qq.com
 * @Date: 2024-05-19 12:24:05
 * @LastEditors: guandeshen 295570679@qq.com
 * @LastEditTime: 2024-09-23 16:30:25
 * @FilePath: /task-admin/src/api/wbs/model.ts
 * @Description:
 *
 * Copyright (c) 2024 by ${git_name_email}, All Rights Reserved.
 */
/**
 * 列表
 */
export interface WBSList {
  id: string;
  wbs_name?: string;
  start_d?: string;
  end_d?: string;
  wbs_description?: string;
  status?: number;
  create_time?: string;
  schedule?: number;
}

/**
 * 查询对象类型
 */
export interface WBSQuery extends PageQuery {
  project_id?: string;
  site_id?: string;
  keyword?: string;
  status?: number;
}

export interface WBSProjectQuery extends PageQuery {
  keyword?: string;
}

export interface detailQuery {
  id: string;
}

export interface ProjectInfoForm {
  id?: string;
  ref?: string;
  p_name?: string;
  p_no?: string;
  p_manager?: string;
  p_contact?: string;
  start_d?: string;
  end_d?: string;
  contract_t?: string;
  status?: number;
  estimated_amount?: string;
  actual_amount?: string;
  remark?: string;
  status_text?: string;
  schedule?: number;
}

export interface WBSInfoForm {
  id?: string;
  ref?: string;
  tenant_id?: string;
  project_id?: string;
  site_id?: string;
  wbs_name?: string;
  wbs_description?: string;
  start_d?: string;
  end_d?: string;
  islock?: number;
  is_milestone?: number;
  early_start_dependency?: string;
  status?: number;
  created?: string;
  create_time?: string;
  updated?: string;
  update_time?: string;
  delete_time?: string;
  schedule?: number;
}
export interface SystemInfoForm {
  created?: string;
  create_time?: string;
  updated?: string;
  update_time?: string;
}

export interface GoodsInfo {
  id?: string;
  ref?: string;
  asset_id?: string;
  asset_type?: string;
  asset_name?: string;
  unit_price?: string;
  total_price?: number;
  unit?: string;
  num?: number;
  stock?: number;
  supplier_name?: string;
  created?: string;
  days?: number;
  create_time?: string;
}

export interface WbsUsersInfo {
  id?: string;
  ref?: string;
  daily_wage?: string;
  user_ref?: string;
  nickname?: string;
  type_of_work?: string;
  created?: string;
  gender?: number;
  mobile?: string;
  days?: number;
  group_name?: string;
}

/**
 * 表单对象类型
 */
export interface WBSForm {
  project_info?: ProjectInfoForm;
  wbs_info: WBSInfoForm;
  system_info?: SystemInfoForm;
  sale_goods?: GoodsInfo[];
  lease_goods?: GoodsInfo[];
  wbs_users?: WbsUsersInfo[];
}

/**
 * 列表
 */
export interface ISite {
  id: string;
  ref?: string;
  project_id?: string;
  s_name?: string;
  s_address?: string;
}
export interface WBSProjectList {
  id: string;
  ref?: string;
  p_name?: string;
  p_no?: string;
  status?: number; //1=投标中,2=已中标,3=未中标
  sites?: ISite[];
  status_text?: string;
  process?: number;
}
